cmake_minimum_required(VERSION 3.28)
project(parser)
# SET(CMAKE_BUILD_TYPE "Debug")
# SET(CMAKE_CXX_FLAGS_DEBUG "$ENV{CXXFLAGS} -O0 -Wall -g2 -ggdb")
# SET(CMAKE_CXX_FLAGS_RELEASE "$ENV{CXXFLAGS} -O3 -Wall")
set(CMAKE_CXX_FLAGS " ${CMAKE_CXX_FLAGS} -Wall -fexec-charset=UTF-8")

include_directories(${CMAKE_SOURCE_DIR}/include)
set(EXECUTABLE_OUTPUT_PATH ${CMAKE_SOURCE_DIR}/)
set(LIBRARY_OUTPUT_PATH ${CMAKE_SOURCE_DIR}/)
add_library(parser SHARED ${CMAKE_SOURCE_DIR}/src/Json.cpp ${CMAKE_SOURCE_DIR}/src/Parser.cpp)

# aux_source_directory(${CMAKE_SOURCE_DIR}/src SRC)
# add_executable(json ${SRC})
add_executable(json ${CMAKE_SOURCE_DIR}/src/main.cpp)
target_link_libraries(json parser)